<!DOCTYPE html>
<html>

<head>
    <title>学生成绩管理系统 - 登录</title>
    <link rel="stylesheet" href="/static/css/login.css">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>

<body>
    <div class="login-container">
        <div class="login-box">
            <h1>学生成绩管理系统</h1>
            <div class="welcome-box">
                <h2>欢迎回来</h2>
                <p class="welcome-text">请登录您的账户继续操作</p>
            </div>

            <form method="post" action="{% url 'accounts:login' %}">
                {% csrf_token %}
                {% if error_message %}
                <div class="error-message">
                    <i class="error-icon">⚠️</i> {{ error_message }}
                </div>
                {% endif %}

                <div class="form-group">
                    <input type="text" name="username" placeholder="请输入用户名" required autocomplete="username">
                </div>

                <div class="form-group">
                    <input type="password" name="password" placeholder="请输入密码" required autocomplete="current-password">
                    <div class="password-options">
                        <label>
                            <input type="checkbox" name="remember_password" id="remember">
                            <span>记住我的密码</span>
                        </label>
                    </div>
                </div>

                <button type="submit" class="login-button">登 录</button>

                <div class="forgot-password">
                    <a href="#">忘记密码？</a>
                </div>
            </form>
        </div>
    </div>
</body>

</html>